﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;

namespace AGPR.Locadora.Utils
{
    public class ValorValidationAttribute : ValidationAttribute
    {
        public ValorValidationAttribute() : base("Valor fora do permitido")
        {
        }

        public override bool IsValid(object value)            
        {
            var valor = (decimal)value;
 	         
            return valor > 0;
        }
    }
}